﻿using System;
using Simple.CMS.Core;

namespace Simple.CMS.Entities
{
    /// <summary>
    /// 管理员用户
    /// </summary>
    public class AdminUser: EntityBase
    {
        /// <summary>
        /// 邮箱
        /// </summary>
        public string Email { get; set; }

        /// <summary>
        /// 角色
        /// </summary>
        public UserRole Role { get; set; }

        /// <summary>
        /// 显示名
        /// </summary>
        public string DisplayName { get; set; }

        /// <summary>
        /// 头像
        /// </summary>
        public string HeadImg { get; set; }

        /// <summary>
        /// 盐值
        /// </summary>
        public string Salt { get; set; }

        /// <summary>
        /// 密码
        /// </summary>
        public string Password { get; set; }

        /// <summary>
        /// 状态
        /// </summary>
        public UserStatus Status { get; set; }

        /// <summary>
        /// 是否要更改密码
        /// </summary>
        public bool NeedChangePwd { get; set; }

        /// <summary>
        /// 上次登录IP
        /// </summary>
        public string LastLoginIp { get; set; }

        /// <summary>
        /// 上次登录时间
        /// </summary>
        public DateTime? LastLoginTime { get; set; }

        /// <summary>
        /// 锁定时间
        /// </summary>
        public DateTime? LockTime { get; set; }

        /// <summary>
        /// 密码错误次数
        /// </summary>
        public int PwdIncorrectTimes { get; set; }


    }
}
